fix a potential issue in the pipeline pass#217
Closed
scxiao wants to merge 1 commit intotriton-mlirfrom
Closed
Conversation
|
@scxiao Can you provide more context about the problem?
|
Author
|
|
@scxiao So with the current llvm, |
Author
|
Changes in this PR is also included in in @jayfurmanek upstream PR #219, so close this PR. |
guacamoleo
pushed a commit
that referenced
this pull request
Dec 10, 2025
…217) Implements the proposal in ROCm/triton-internal#1318. For Gluon instead of following the tokens, which are difficult to loop carry in gluon, we define the waitCnt as number of commit groups ops in Gluon. The UpdateAsyncWaitCnt pass will then walk the IR backwards and computes the minimum number of created async intrinsic by waitCnt outstanding commit groups. Current limitations are: We treat dynamic and static loops the same. This means we could get conservative loads if the prologue prefetch loop is not unrolled. For our Gluon kernels they were always unrolled. I can add support in a follow up PR since this one is already quite large. scf.ExecuteRegion is not handled to keep the PR minimal. But adding support for it is trivial when the new PingPong lands Warp specialization is not handled. We will probably use LDS/Named barriers so this might not be needed? Adding it should also be not a problem in case we need it. Note that for TDM each tensor_load/store in TGGIR will create exactly one intrinsic so we can use the count from Gluon directly.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The fix here is relate to the function call of
op.getResult(0), in which an op could have zero results, then this function call will have an assert failed.The fix is to check the number of results of an op before calling this function. Only if an op has 1 or more results, will the function
op.getResultcalled.